<?
class BannerBO extends BusinessObject{

  /* private function using in constructors */ 
  function setAttributes(){
	$this->fields	= array(
				'id'	=> 'bannerID',
				'side'	=> 'bannerSide',
				'viewCount'	=> 'bannerViewCount',
				'clickCount'	=> 'bannerClickCount',
				'owner'	=> 'bannerOwner',
				'title'	=> 'bannerTitle',
				'alt'	=> 'bannerAlt',
				'URL'	=> 'bannerURL',
				'image'	=> 'bannerImage',
				'type'	=> 'bannerType',
				'state'	=> 'bannerState',
				'sizeX'	=> 'bannerSizeX',
				'sizeY'	=> 'bannerSizeY',
				'imprLeft'	=> 'bannerImprLeft',
				'timeLeft'	=> 'bannerTimeLeft',
				'finishTime'	=> 'bannerFinishTime',
				'unlimImpr'	=> 'bannerUnlimImpr',
				'access'	=> 'bannerAccess',
				'onClickValue'	=> 'bannerOnClickValue',
				'onClickType'	=> 'bannerOnClickType',
				'script'	=> 'bannerScript',
				'creationDate'	=> 'bannerCreationDate',
				'showLocation'	=> 'bannerShowLocation',
				'regionID'	=> 'bannerRegionID'
				);
		$ab= new ArticleBannerBO();
		$this->relations = array("{$ab->tableName}" =>"{$ab->tableName}.{$ab->fields['banner']} = {$this->tableName}.{$this->fields['id']}");
    BusinessObject::setAttributes();
  }
 
  /* constructor */
  function BannerBO(){
    /** super(tableName) */
    BusinessObject::BusinessObject("banners");
    $this->setAttributes();
  }
}
?>
